#pragma once

#include "mqtt_client_interface.h"

#include <memory>
#include <string>

class MQTTClientBuilder
{
public:
    MQTTClientBuilder &set_server_uri(const std::string &val);
    MQTTClientBuilder &set_client_id(const std::string &val);
    MQTTClientBuilder &set_client_username(const std::string &val);
    MQTTClientBuilder &set_client_password(const std::string &val);
    MQTTClientBuilder &set_client_ssl_filepath_ca(const std::string &val);
    MQTTClientBuilder &set_client_ssl_filepath_client_cert(const std::string &val);
    MQTTClientBuilder &set_client_ssl_filepath_client_key(const std::string &val);
    MQTTClientBuilder &set_client_ssl_filepath_client_key_password(const std::string &val);
    MQTTClientBuilder &set_connect_timeout_s(const int &val);

    std::shared_ptr<MQTTClientInterface> build();

private:
    std::string server_uri_;
    std::string client_id_;
    std::string client_username_;
    std::string client_password_;
    std::string client_ssl_filepath_ca_;
    std::string client_ssl_filepath_client_cert_;
    std::string client_ssl_filepath_client_key_;
    std::string client_ssl_filepath_client_key_password_;
    int         connect_timeout_s_;
};